<%@ taglib prefix="c" uri="http://java.sun.com/jsp/jstl/core" %>
<%@ taglib prefix="fmt" uri="http://java.sun.com/jsp/jstl/fmt" %>
<%--
  Created by IntelliJ IDEA.
  User: LV
  Date: 2016/7/4
  Time: 9:03
  To change this template use File | Settings | File Templates.
--%>
<%@ page contentType="text/html;charset=UTF-8" language="java" %>
<html>
<head>
    <title>订单详情</title>
</head>
<body>
<div class="navigation">
    <div class="crumbs ">
        <i class="tm-iconfont icon-info"></i>
        <a href="#">卖家中心</a><span>&gt;</span><a href="#200">交易管理</a><span>&gt;</span>订单详情
    </div>
    <div class="help">
        <a href="#" target="_blank">卖家交易学习专区</a>
    </div>
</div>
<!--订单详情 star-->
<div class="order_details">
    <div class="p10 b-fffcf3 la-ffcc66">
        <div class="p-l20">
            <div class="fs14">当前订单状态：
                <c:if test="${orderModel.oOrder.orderStatus==-1}">订单关闭</c:if>
                <c:if test="${orderModel.oOrder.orderStatus==0}">买家未付款</c:if>
                <c:if test="${orderModel.oOrder.orderStatus==1}">买家已支付，等待发货</c:if>
                <c:if test="${orderModel.oOrder.orderStatus==2}">卖家已发货</c:if>
                <c:if test="${orderModel.oOrder.orderStatus==3}">买家已收货，交易完成</c:if>
            </div>
            <c:if test="${orderModel.oOrder.orderStatus==3}">
            <div class="c-FF0000">联城提醒您</div>
            <div>交易已成功，如果买家提出售后要求，请积极与买家协商，做好售后服务。</div>
            </c:if>
        </div>
    </div>
    <!--star 订单信息-->
    <div class="mtc_box m-t20 line-all b-F5F5F5">
        <div class="mt line-bottom p-lr10 fs14">订单信息</div>
        <!--mc star-->
        <div class="mc b-FFFFFF p10">
            <!--star 01-->
            <div>
                <p>订单编号：${orderModel.oOrder.orderNum}</p>
                <p>下单时间：<fmt:formatDate value="${orderModel.oOrder.orderTime}" pattern="yyyy-MM-dd HH:mm:ss"></fmt:formatDate></p>
                <p>付款时间：<fmt:formatDate value="${orderModel.oOrder.paymentTime}" pattern="yyyy-MM-dd HH:mm:ss"></fmt:formatDate></p>
                <p>收货确认时间：<fmt:formatDate value="${orderModel.oOrder.goodsGetTime}" pattern="yyyy-MM-dd HH:mm:ss"></fmt:formatDate></p>
                <p>买家账户：${changePhoneNum}</p>
                <p>订单总价：￥${orderModel.oOrder.totalOrderAmount}</p>
                <p>收货地址 ：${orderModel.oOrder.consigneeName}，${orderModel.oOrder.consigneePhone}，${orderModel.oOrder.provinceName} ${orderModel.oOrder.cityName} ${orderModel.oOrder.districtName} ${orderModel.oOrder.streetName} ${orderModel.oOrder.address}</p>
            </div>
            <!--end 01-->
            <!--star 02-->
            <div class="oh c m-tb10 line-top">
                <h2 class="h40 fs14">订单商品：</h2>
                <div class="u_table_list table001">
                    <!--star 名称-->
                    <div class="mtt line-left line-right line-top">
                        <table>
                            <colgroup>
                                <col width="45%">
                                <col width="15%">
                                <col width="10%">
                                <col width="10%">
                                <col width="10%">
                                <col width="10%">
                            </colgroup>
                            <tbody>
                            <tr class="fwb">
                                <th>商品</th>
                                <th>规格</th>
                                <th>单价（元）</th>
                                <th>数量</th>
                                <th>商品总价</th>
                                <th>运费（元）</th>
                            </tr>
                            </tbody>

                            <tbody>
                            <tr>
                                <td>
                                    <div class="product_name">
                                        <div class="t_img"><img src="${orderModel.orderProductsEntityList[0].image}" /></div>
                                        <div class="t_info">
                                            <a href="#">${orderModel.orderProductsEntityList[0].title}</a>
                                        </div>
                                    </div>
                                </td>
                                <td><span class="c-999999">${orderModel.orderProductsEntityList[0].attribute}</span></td>
                                <td>${orderModel.orderProductsEntityList[0].price}</td>
                                <td>${orderModel.orderProductsEntityList[0].quantity}</td>

                                <td rowspan="${orderModel.orderProductsEntityList.size()}" class="tac">
                                    <div class="fwb">${orderModel.oOrder.totalProductAmount}</div>
                                </td>
                                <td rowspan="${orderModel.orderProductsEntityList.size()}" class="tac">快递:${orderModel.oOrder.totalFreightAmount}</td>
                            </tr>

                            <c:forEach items="${orderModel.orderProductsEntityList}" var="list" begin="1">
                            <tr>
                                <td>
                                    <div class="product_name">
                                        <div class="t_img"><img src="${list.image}" /></div>
                                        <div class="t_info">
                                            <a href="#">${list.title}</a>
                                        </div>
                                    </div>
                                </td>
                                <td><span class="c-999999">${list.attribute}</span></td>
                                <td>${list.price}</td>
                                <td>${list.quantity}</td>
                            </tr>
                            </c:forEach>

                            </tbody>
                        </table>
                    </div>
                    <!--end 商品-->
                </div>
            </div>
            <!--end 02-->
        </div>
        <!--mc end-->
    </div>
    <!--end 订单信息-->
    <!--star 物流信息-->
    <div class="mtc_box m-t20 line-all b-F5F5F5">
        <div class="mt line-bottom p-lr10 fs14">物流信息</div>
        <!--mc star-->
        <div class="mc b-FFFFFF p10">
            <!--star 01-->
            <div class="p-lr20">
                <p>物流公司：${orderModel.oOrder.shippingCompanyName}</p>
                <p>运单号码：${orderModel.oOrder.shippingTrackingNumber}</p>
                <p>物流跟踪：</p>
                <p>无物流信息</p>

            </div>
            <!--end 01-->
        </div>
        <!--mc end-->
    </div>
    <!--end 物流信息-->
    <!--star 订单日志-->
    <div class="mtc_box m-t20 line-all b-F5F5F5">
        <div class="mt line-bottom p-lr10 fs14">订单日志</div>
        <!--mc star-->
        <div class="mc b-FFFFFF p10">
            <!--star 01-->
            <div class="p-lr20">
                <c:forEach items="${orderHistoryList}" var="list">
                    <p><fmt:formatDate value="${list.createOn}" pattern="yyyy-MM-dd HH:mm:ss"></fmt:formatDate> ${list.comment}<p>
                </c:forEach>
            </div>
            <!--end 01-->
        </div>
        <!--mc end-->
    </div>
    <!--end 订单日志-->
</div>
<!--订单详情 end -->

<div class="tac p-t40">
    <a href="${ctx}/order/getAllOrdersByStatus?status=${orderModel.oOrder.orderStatus}"><button class="i_btn u2 p-lr50">返回订单列表</button></a>
    <div style="padding-bottom:100px; height:10px;"></div>
</div>
</body>
</html>
